﻿

namespace Patterns4Net.ArchitectureExplorer.ViewModels.Graph
{
    using Infrastructure;
    using System.ComponentModel.Composition;
    using Graphviz4Net.Graphs;
    using Attributes;

    [Export(typeof(GraphViewModel))]
    public class GraphViewModel : 
        Graph<VertexViewModel, SubGraphViewModel, RelationViewModel<VertexViewModel>, RelationViewModel<SubGraphViewModel>>
    {
        public GraphViewModel(AbstractionLevel level, Settings settings)
        {
            this.AbstractionLevel = level;
            foreach (var attribute in settings.AdditionalGraphAttributes)
            {
                this.Attributes.Add(attribute);
            }
        }

        public AbstractionLevel AbstractionLevel { get; private set; }
    }
}
